import { userInfoNew } from '@/api/storeInfo';
export default {
  state: {
    storeCode: '',
    storeId: '',
    storeList: []
  },
  mutations: {
    setStoreId (state, id) {
      state.storeId = id
    },
    setStoreCode (state, storeCode) {
      state.storeCode = storeCode
    },
    setStoreName (state, storeName) {
      state.storeName = storeName
    },
    setStoreList (state, storeList) {
      state.storeList = storeList
    }
  },
  getters: {

  },
  actions: {
    // 获取用户相关信息
    getUserInfoNew ({ commit }, {}) {
      return new Promise((resolve, reject) => {
        userInfoNew({
        }).then(res => {
          resolve(res.data);
        }).catch(err => {
          reject(err)
        })
      })
    }
  }
}
